package com.chen.controller;

import com.chen.excel.SysUserExcelExport;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;
import java.util.HashMap;
import java.util.Map;

@RestController
@RequestMapping(value = "sysUserExport")
@Slf4j
public class SysUserExportController {

    @Resource
    private SysUserExcelExport sysUserExcelExport;

    /**
     * 导出数据
     */
    @GetMapping("exportData")
    public void exportData() {
        //指定查询的数据条件（根据什么查询）
        Map<String, Object> map = new HashMap<>();
        //文件名，查询条件
        sysUserExcelExport.exportWithBigData("用户列表", map);
    }

}